/*
 *  /linux-3.0.8/drivers/media/video/vcam_test.h
*/
#ifndef __VCAM_TEST_H
#define __VCAM_TEST_H



/***** user control data structure *****/
#define NB_BUFFER 4
#define DEVICE_NAME_LEN 20

struct vcam_in {
	struct v4l2_capability capability;
	struct v4l2_format format;
	struct v4l2_buffer buffer;
	struct v4l2_streamparm streamparm;
	struct v4l2_requestbuffers requestbuffers;
	
	char dev_name[DEVICE_NAME_LEN];
	
	void *mem[NB_BUFFER];
	unsigned char *tmp_buffer;
	unsigned char *frame_buffer;
	char *status;
	char *picture_name;
	int fd;

	int width;
	int height;
	int fps;
	int is_streaming;
	int grab_method;
	
	int in_format;
	int out_format;
	int in_framesize;
	int signal_quit;
	int toggle_avi;
	int get_picture;
	int raw_frame_capture;
	unsigned int file_counter;

	unsigned int rfs_written_frames;
	unsigned int rfs_written_bytes;

	FILE *capture_file;
	unsigned int written_frames;
	unsigned int written_bytes;
	int frame_count;
	int record_start;
	int record_time;
};

struct vcam_out {

	struct fb_var_screeninfo var_screeninfo;
	struct fb_fix_screeninfo fix_screeninfo;
	char dev_name[DEVICE_NAME_LEN];
	unsigned char *fb_buffer;
	int fd;
	unsigned int fb_size;
};

struct vcam_control_info{
	struct vcam_in in;
	struct vcam_out  out;
};


#define VCAM_TEST_VERSION "1.0"



#endif

